﻿@{
    ViewBag.Title = "用户注册";
    Layout = GetPath(SystemDirectory.Shared, "_Dialog.cshtml");
}

@model RegisterModel

@if (IsValided)
{
<div class="container">
	<form enctype="multipart/form-data" method="post">
        <div><span class="left">用户名</span> @Html.ValidationMessageFor(m => m.UserName)@Html.TextBoxFor(model => model.UserName)</div>
        <div><span class="left">密码</span> @Html.ValidationMessageFor(m => m.Password)@Html.PasswordFor(model => model.Password)</div>
        <div><span class="left">确认密码</span> @Html.ValidationMessageFor(m => m.ConfirmPassword)@Html.PasswordFor(model => model.ConfirmPassword)</div>
        <div><span class="left">电子邮件</span> @Html.ValidationMessageFor(m => m.Email)@Html.TextBoxFor(model => model.Email)</div>
        @if (Settings.QuestionAnswer)
        {
        <div><span class="left">密码问题</span> @Html.ValidationMessageFor(m => m.PasswordQuestion)@Html.TextBoxFor(model => model.PasswordQuestion)</div>
        <div><span class="left">问题答案</span> @Html.ValidationMessageFor(m => m.PasswordAnswer)@Html.TextBoxFor(model => model.PasswordAnswer)</div>
        }
        @if (Settings.AccountActivation == AccountActivation.InvitationOnly)
        {
        <div><span class="left">邀请码</span> @Html.ValidationMessageFor(m => m.PublicKey)@Html.TextBoxFor(model => model.PublicKey)</div>
        }
        <div class="tcenter">
            <button class="button" type="submit">注册新帐户</button>
        </div>
    </form>
</div>
}
    